@import '~@/styles/themes/var';

$panel_width: 233px;

.com-panel-wp {
  flex: none;
  z-index: 4;
  width: $panel_width !important;
  height: 100%;
  overflow: hidden;
  background: $panel-bgcolor;
  box-shadow: 1px 0 #000;
  transition: width 0.3s ease;
}

.com-panel {
  position: relative;
  display: flex;
  width: $panel_width;
  height: 100%;
  overflow: hidden;
  transition: 0.3s ease;
  user-select: none;
  flex-direction: column;

  .panel-title {
    display: flex;
    height: 30px;
    padding: 10px;
    color: $panel-font-color;
    background: $layer-bgcolor;
    user-select: none;
    align-items: center;
    justify-content: space-between;

    .close-btn {
      cursor: pointer;
      transition: color 0.2s;

      &:hover {
        color: $color-primary;
      }
    }
  }

  .menu-item {
    display: inline-block;
    width: 80px;
    margin: 5px;
    color: $panel-font-color;
    vertical-align: top;
    cursor: pointer;
    user-select: none;
    flex: 1;

    .menu-item-img {
      position: relative;
      width: 100%;
      height: 45px;
      overflow: hidden;
      text-align: center;
      pointer-events: none;
      background-position: center;
      background-repeat: no-repeat;
      background-size: cover;
      border: 1px solid transparent;
      box-sizing: content-box;
      transition: border-color 0.2s;
      background-clip: content-box;
    }

    .menu-item-text {
      display: -webkit-box;
      padding: 0;
      margin-top: 3px;
      margin-bottom: 17px;
      overflow: hidden;
      font-size: 12px;
      line-height: 1.2;
      text-align: left;
      text-overflow: ellipsis;
      -webkit-box-orient: vertical;
    }

    &:hover {
      .menu-item-img {
        border-color: $panel-img-border-color;
      }
    }
  }
}

.com-panel-wp.--hide {
  width: 0 !important;

  .com-panel {
    transform: translateX(-100%);
  }
}

.com-tab-icon {
  font-size: 16px;
}

.collpase-hd-text {
  margin-left: 5px;
  font-size: 12px;
}

.collpase-hd-icon {
  padding-left: 5px;
}

.favorite-empty {
  padding: 10px;
  margin: 30px 0 0 0;
  font-size: 12px;
  color: $layer-font-color;
  text-align: center;
}

.com-search-wp {
  position: relative;
  display: flex;
  align-items: center;
  height: 32px;
  background: $tabs-nav-bgcolor;
}
